An electric generator for an aircraft is coupled to an aircraft engine to produce electricity. In accordance with one embodiment, the electric generator has a variable frequency. An electric generator of this type comprises, inter alia:                a sealed casing so as to maintain a pressure close to the atmospheric pressure within the casing;        a rotating shaft, which infiltrates the interior of the casing via an opening;        a gasket between the rotating shaft and the casing; and        a relief valve configured to place the interior of the casing in communication with the exterior of the casing if the pressure inside the casing exceeds a given value.        
During operation, the rotating shaft has a very high speed of rotation (between 12000 and 24000 revolutions per minute, an average speed of rotation of 16000 revolutions per minute during the cruising phase). The gasket utilizes a separation effect, which tends to space the gasket slightly from the rotating shaft.
In accordance with the above, an increase of the pressure within the casing is observed flight after flight. After a certain number of flights, the relief valve opens and a flow of oil develops.
The present disclosure aims to overcome this disadvantage of the prior art.